﻿using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace WeatherSystem.Data.Response
{
    class TextMsg : ResponseMessageBase
    {
        protected override ResponseMessageType msgType => ResponseMessageType.Text;
        public string Content { get; set; }
        public TextMsg(string to, string from, long time, string content) : base(to, from, time)
        {
            Content = AddCdataMark(content);
            ToUserName = AddCdataMark(to);
            FromUserName = AddCdataMark(from);
        }
        public override JObject GetJobject()
        {
            JObject jo = JObject.FromObject(this);
            return jo;
        }
    }
}
